Data independent error computation and usage with decision directed error computation

ABSTRACT

An analog front end is adjusted by determining a signal quality based at least in part on digital sample(s). If the signal quality satisfies one or more criteria, a data independent gain gradient and a data independent offset gradient are selected to adjust the analog front end, where the two gradients are generated without taking into consideration an instantaneous value of an expected signal. If the signal quality does not satisfy the criteria, a decision directed gain gradient and a decision directed offset gradient are selected to adjust the analog front end, where the two gradients are generated based at least in part on decision(s).

CROSS-REFERENCE TO OTHER APPLICATIONS

This application is a continuation of co-pending U.S. patent application Ser. No. 13/012,640 entitled DATA INDEPENDENT ERROR COMPUTATION AND USAGE WITH DECISION DIRECTED ERROR COMPUTATION filed Jan. 24, 2011 which claims priority to U.S. Provisional Patent Application No. 61/336,986 entitled SWITCHING BETWEEN DECISION-DIRECTED AND NON DECISION-DIRECTED CONTROL LOOPS BASED ON SIGNAL filed Jan. 29, 2010 which are incorporated herein by reference for all purposes.

BACKGROUND OF THE INVENTION

In some communications and storage systems, an analog front end component or processor processes an analog signal which is then converted into digital samples using an analog to digital converter (ADC). Some examples of analog front end processing include filtering to prevent aliasing, removing any DC offset, adjusting gain, etc. The digital samples are then processed by a digital back end component or processor, for example, which uses one or more detectors (also referred to as decoders) to perform error correction decoding. The performance of the overall system (e.g., measured as bit error rate, throughput, etc.) depends upon the performance of the analog front end. It would therefore be desirable to improve the performance of analog front end components or processors so that the performance of the overall system can be improved (e.g., assuming a same or constant level of noise) and/or the system is able to operate under even noisier conditions than before.

BRIEF DESCRIPTION OF THE DRAWINGS

Various embodiments of the invention are disclosed in the following detailed description and the accompanying drawings.

FIG. 1 is a block diagram showing an embodiment of a data independent error computation block used to determine error associated with gain and offset.

FIG. 2 is a flowchart illustrating an embodiment of a process for determining an error signal in a data independent manner.

FIG. 3 is a flowchart illustrating an embodiment of a process for determining an offset gradient.

FIG. 4A is a flowchart illustrating an embodiment of a process for determining a gain gradient using the expected value of the square of an expected signal.

FIG. 4B is a flowchart illustrating an embodiment of a process for determining a gain gradient using the expected value of the absolute value of an expected signal.

FIG. 5 is a block diagram showing an embodiment of a system which uses signal quality to select between data independent error correction and decision directed error correction.

FIG. 6 is a diagram showing an embodiment of a data structure.

FIG. 7 is a flowchart illustrating an embodiment of a technique to determine an average amplitude and average offset in order to select an error correction technique.

FIG. 8A is a flowchart illustrating an embodiment of a technique to determine an amplitude difference metric and offset difference metric in order to select an error correction technique.

FIG. 8B is a diagram showing exemplary plots of an amplitude difference metric and an offset difference metric.

FIG. 9A is a flowchart illustrating an embodiment of a technique to determine a synchronization mark distance in order to select an error correction technique.

FIG. 9B is a diagram showing an embodiment of synchronization mark distance plotted as a function of a noise factor.

DETAILED DESCRIPTION

The invention can be implemented in numerous ways, including as a process; an apparatus; a system; a composition of matter; a computer program product embodied on a computer readable storage medium; and/or a processor, such as a processor configured to execute instructions stored on and/or provided by a memory coupled to the processor. In this specification, these implementations, or any other form that the invention may take, may be referred to as techniques. In general, the order of the steps of disclosed processes may be altered within the scope of the invention. Unless stated otherwise, a component such as a processor or a memory described as being configured to perform a task may be implemented as a general component that is temporarily configured to perform the task at a given time or a specific component that is manufactured to perform the task. As used herein, the term ‘processor’ refers to one or more devices, circuits, and/or processing cores configured to process data, such as computer program instructions.

A detailed description of one or more embodiments of the invention is provided below along with accompanying figures that illustrate the principles of the invention. The invention is described in connection with such embodiments, but the invention is not limited to any embodiment. The scope of the invention is limited only by the claims and the invention encompasses numerous alternatives, modifications and equivalents. Numerous specific details are set forth in the following description in order to provide a thorough understanding of the invention. These details are provided for the purpose of example and the invention may be practiced according to the claims without some or all of these specific details. For the purpose of clarity, technical material that is known in the technical fields related to the invention has not been described in detail so that the invention is not unnecessarily obscured.

FIG. 1 is a block diagram showing an embodiment of a data independent error computation block used to determine error associated with gain and offset. In various embodiments, the system is used in a variety of applications (e.g., storage or wired/wireless communication) and the signal in may come from a variety of sources (e.g., storage media, wireless transmission channel, wire-line transmission channel, etc.) and the techniques described herein are included in a variety of corresponding systems (e.g., a read channel processor in a storage application or a receiver in a communications application).

In the example shown, a signal in is passed to analog front end 100. Analog front end 100 performs a variety of processing on the input signal to obtain a groomed analog signal x(t), which satisfies the requirements of downstream blocks. For example, it may be that analog to digital converter (ADC) 102 is expecting the analog signal x(t) to occupy a full dynamic range (but without exceeding a ceiling otherwise clipping may occur) and analog front end 100 processes the signal in to achieve this goal in the resulting signal x(t). In various embodiments, analog front end 100 performs filtering to prevent aliasing of the digitized signal and/or compensates for or otherwise adjusts signal characteristics such as gain and/or DC offset.

ADC 102 inputs analog signal x(t) and outputs digital samples x_(k). The digital samples x_(k) are passed to digital back end 104 which generates a signal out. In some embodiments, the signal in is encoded using an error correction code or error detection code and error correction/detection decoding is performed by digital back end 104. Some example error correction codes include low-density parity-check (LDPC) codes and Reed-Solomon codes, but any code may be used.

The digital samples x_(k) are also passed to data independent error computation block 106. This block is described in further detail below. In this example, data independent error computation block 106 outputs two signal errors: one associated with gain (a gain gradient) and one associated with a (DC) offset (an offset gradient). The gain and offset gradients are passed respectively to low pass filters (LPF) 108 a and 108 b. The low pass filters perform averaging and produce a gain compensation G^((k+1)) and offset compensation (O^((k+1))), which depend upon the previous compensation value (i.e., G^((k)) or O^((k))), a bandwidth value (κ) and the gradient ({tilde over (∇)}). In this example, G^((k+1))=G^((k))+κ_(G)·{tilde over (∇)}_(G) and O^((k+1))=O^((k))+κ_(O)·{tilde over (∇)}_(O) ^((k)).

Using the gain compensation and offset compensation passed to analog front end 100, parameters associated with adjusting gain or offset are adjusted as needed by analog front end 100. For example, with respect to gain there may be an amplifier included in analog front end 100 and the gain setting of the amplifier is adjusted based on the gain compensation value. Although the example of FIG. 1 shows a data independent error computation block which outputs gradients which are passed to low pass filters, the techniques described herein may be used in any system and/or configuration.

In contrast to data aided error correction, the instantaneous value of the expected signal (i.e., the actual value of the original transmitted/stored data without any noise or distortion) is not known in data independent error correction and it is therefore not used in determining an error signal by data independent error computation block 106. Using a 4-bit sequence as an example, the possible values (without any noise) are 0000, 0001, . . . , 1110, 1111. In a data aided system, the instantaneous value of the expected signal is known a priori so that the system knows ahead of time that the original stored or transmitted bit sequence is (as an example) 0101 as opposed to the other possible values. In contrast, data independent error computation block 106 determines one or more signal errors (in this example, a gain gradient and an offset gradient) without knowing or using the instantaneous value of the expected signal. Instead, the data independent error technique described herein uses one or more known properties of the expected signal (i.e., properties of the original transmitted/stored signal without any noise) and does not rely upon the instantaneous value of the expected signal. Some examples of known properties include the expected value (also referred to as the mean) of the expected signal, the expected value of the absolute value of the expected signal, the variance of the expected signal, etc. One advantage to data independent error computation over data aided error computation is that in many cases the data is not known ahead of time. For example, in wireless or storage applications, the data received over the communications channel or read back from the storage media is typically not known ahead of time. Data aided techniques may therefore require the occasional introduction of known or pre-agreed upon patterns, which incurs a performance or bandwidth penalty.

In decision directed error computation, a signal error (e.g., associated with gain or offset) is calculated using decisions output by a detector (also referred to as a decoder), which processes encoded data. Unlike data aided error computation, the instantaneous value of the expected signal is not known ahead of time in decision directed error computation, but the decoder will make a decision about what it thinks the received signal is. When the received signal includes a nominal amount of noise, the error correction capabilities of the code will enable the detector to come to a decision that matches the actual (i.e., instantaneous) value of the expected signal. To use the 4-bit example above, the detector would determine that the bit sequence is 0101 after performing decoding processing. However, when the noise included in the received signal is greater than the error correction capabilities of the code, the decision output by the detector will not match the instantaneous or actual value. When comparing data independent error correction and decision directed error correction, data independent error correction differs in that it does not use decisions. As such, data independent error computation block 106 does not include or use a detector. In some cases, data independent error computation is desirable over decision directed error computation. One such scenario is when the quality of the signal is low, for example because the channel is introducing a significant amount of noise. The decisions output by the detector will be poor decisions and the resulting adjustments (e.g., of the gain and offset) may not be based on a proper reflection of the actual conditions of the channel. Another advantage of data independent error computation over decision directed error computation is that it does not require the use of (error correction) codes and the required processing by detectors introduces latency into a decision directed system, which correspondingly introduces latency into the feedback loop. If the channel is changing quickly, a long latency may be undesirable because the conditions have changed and the signal error calculated is no longer relevant to the current conditions.

In various embodiments, the techniques described herein are implemented in a variety of systems or forms. In some embodiments, the techniques are implemented in hardware as an application-specific integrated circuit (ASIC) or a field-programmable gate array (FPGA). In some embodiments, a processor (e.g., an embedded one such as an ARM core) is used where the processor is provided or loaded with instructions to perform the techniques described herein. In some embodiments, the technique is implemented as a computer program product which is embodied in a computer readable storage medium and comprises computer instructions.

FIG. 2 is a flowchart illustrating an embodiment of a process for determining an error signal in a data independent manner. In some embodiments, data independent error computation block 106 in FIG. 1 performs the process shown herein. At 200, a known property of an expected signal is obtained. For example, the error between an expected signal (z_(k)) and a received signal (x_(k)) is: e _(k) =x _(k)(b)−z _(k)(b)  (1) where b is the original (e.g., written or transmitted) data.

The expected signal (z_(k)) is the originally transmitted or stored signal (e.g., without any noise) and the received signal (x_(k)) is the signal observed or seen at the receiver or read processor (e.g., the expected signal with noise included, for example by the channel). Although the expected signal z_(k)(b) may not be known ahead of time by the receiver or read processor (e.g., a storage system may not know a priori the contents of stored data or a receiver may not know the contents of a transmitted message ahead to time), certain properties about the expected signal may be known and obtained. Some examples include statistical properties or characteristics associated with the expected signal such as the mean or expected value (e.g., E[z_(k)(b)]), the expected value of the square of the expected signal (e.g., E[z_(k) ²(b)]), the expected value of the absolute value of the expected signal (e.g., E[|z_(k)(b)|]), etc. In various embodiments, various known properties of the expected signal is/are obtained at 200.

A signal is received at 202. For example, in FIG. 1 the signal x_(k) is received at data independent error computation block 106 from ADC 102. In various embodiments, the received signal may originate from or pass through a variety of channels or media, including a wired/wireless transmission channel or storage media (e.g., Flash or magnetic disk).

At 204, a signal error is determined based at least in part on the received signal and the known property of the expected signal. In some embodiments, the signal error is associated with an adjustment performed on an analog signal (e.g., prior to analog to digital conversion). In the example of FIG. 1, two signal errors (associated with gain and offset) are determined. In some other embodiments, other types of signal errors (e.g., associated with filtering or timing) are determined.

To help illustrate the techniques described herein, the following figures describe some specific examples of the technique shown in FIG. 2. FIG. 3 describes an example which determines a signal error associated with offset and FIGS. 4A and 4B describe examples which determine signal errors associated with gain. Although the examples of FIGS. 4A-4B show examples using a least squares optimization technique, any optimization or selection technique may be used to determine an error signal that is based at least in part on one or more known properties of an expected signal.

FIG. 3 is a flowchart illustrating an embodiment of a process for determining an offset gradient. In some embodiments, data independent error computation block 106 in FIG. 1 performs the example process of FIG. 3. At 300, the expected value of an expected signal is obtained (e.g., E[z_(k)(b)]). At 302, a signal is received. At 304, the expected value of the expected signal is subtracted from the received signal to obtain an offset gradient. That is: {tilde over (∇)}_(O) ^((k)) =x _(k)(b)−E[z _(k)(b)]  (2) where the expectation in Equation 2 is taken is over all possible values of b.

In some cases, the expected signal z_(k)(b) is DC-free (that is, z_(k)(b)=−z_(k)(b⊕1) and the expected value of the expected signal (i.e., E[z_(k)(b)]) goes to or equals zero, provided all bit sequences are written or transmitted (with equal probability), which occurs with probability 1 for a long enough observation period. For applications which encode the stored or transmitted data (e.g., with error correction codes such as LDPC codes or RS codes), the encoded data which is transmitted or stored is evenly distributed and does not tend to “clump” (i.e., have certain values compared to other values) and such applications which use codes have this characteristic where E[z_(k)(b)]→0. For such cases where E[z_(k)(b)] goes to or equals zero, the offset gradient may be expressed as: {tilde over (∇)}_(O) ^((k)) =x _(k)(b)  (3)

To illustrate how Equation 2 (and correspondingly, Equation 3) is obtained, first an offset gradient is determined using least squares based on the instantaneous value of the expected signal or a decision generated by a detector which inputs encoded data and outputs decisions (e.g., as is the case for data aided error correction and decision directed error correction, respectively). From there, an offset gradient is determined that depends only upon known properties of the expected signal and does not depend upon an instantaneous value or a decision.

When using least squares, the objective is to choose the values of any compensation parameters, p, that minimize the expected value of the error squared. That is: E[(e _(k))² ]=E[(x _(k)(b)−z _(k)(b))²]  (4) With respect to the example of FIG. 1, the compensation parameters may be controls associated with analog front end 100, which control gain or offset.

In at least some embodiments, minimization of Equation 4 is solved using a stochastic gradient descent technique, in which a gradient is formed as the derivative of the argument of the expectation with respect to each element of p. That is:

$\begin{matrix} {\frac{\partial e_{k}^{2}}{\partial p_{i}} = {2 \cdot e_{k} \cdot \frac{\partial e_{k}}{\partial p_{i}}}} & (5) \end{matrix}$

Since gain compensation (G) scales the ADC samples and offset compensation (O) adds to the ADC samples, we can express the received signal as: x _(k)(b)=G·{tilde over (x)} _(k)(b)+O  (6) which produces a gain gradient of:

$\begin{matrix} {\nabla_{G}^{(k)}{= {\frac{\partial e_{k}^{2}}{\partial G} = {2 \cdot e_{k} \cdot {{\overset{\sim}{x}}_{k}(b)}}}}} & (7) \end{matrix}$ where {tilde over (x)}_(k)(b) is the pre-compensated ADC sample. A pre-compensated ADC sample is the input to the analog-front-end (i.e., the signal before gain and offset compensation is applied to it). The input to the analog-front-end is a continuous time signal, not a sampled signal, but writing it as a sampled signal makes it possible to express the ADC sample in terms of the gain and offset compensation terms G and O, as is done in Equation 6. In the example of FIG. 1, it is the sampled version of signal in.

The offset gradient is:

$\begin{matrix} {\nabla_{o}^{(k)}{= {\frac{\partial e_{k}^{2}}{\partial o} = {2 \cdot e_{k}}}}} & (8) \end{matrix}$

The gain gradient shown in Equation 7 can be approximated as:

$\begin{matrix} {\nabla_{G}^{(k)}{= {\frac{\partial e_{k}^{2}}{\partial G} = {2 \cdot e_{k} \cdot {x_{k}(b)}}}}} & (9) \end{matrix}$ where x_(k)(b) is the received or observed signal because {tilde over (x)}_(k)(b) from Equation 7 (i.e., the pre-compensated ADC sample) is not available. In contrast, x_(k)(b) is available.

The gradients shown in Equations 8 and 9 are stochastic in nature (since they contain signal noise) and are therefore averaged before being used to update the compensation values of G and O (e.g., by low pass filters 108 a and 108 b in FIG. 1). As a result of this averaging, the gain compensation update equation is: G ^((k+1)) =G ^((k))+κ_(G)·∇_(G) ^((k))  (10) and the offset compensation update equation is: O ^((k+1)) =O ^((k))+κ_(O)·∇_(O) ^((k))  (11) where κ_(G) controls the bandwidth of the LPF associated with gain (e.g., LPF 108 a in FIG. 1) and κ_(O) is the bandwidth of the LPF associated with offset (e.g., LPF 108 b in FIG. 1). Increasing the bandwidths of these filters causes gain and offset variations to be tracked more quickly at the expense of less averaging (i.e., more steady state noise). Reducing bandwidth results in more averaging (i.e., less steady state noise) with longer response times to changes in gain and offset. The bandwidths are therefore selected appropriately, for example based on the particular channel conditions or desired characteristics of the system (e.g., whether (noise) conditions change quickly or tend to be steady state).

In data independent error correction, there is no decoder to provide decisions used in error calculation (as is the case with decision directed error calculation) nor is the instantaneous value of the expected signal known (as is the case with data aided error calculation). The equations above are therefore modified below to incorporate only known properties of the expected signal, as opposed to being dependent upon decisions or instantaneous values of the expected signal.

To begin with, the offset compensation update equation from Equation 11 is rewritten as:

$\begin{matrix} \begin{matrix} {O^{({k + 1})} = {K_{O}{\sum\limits_{- \infty}^{k}\nabla_{O}^{(k)}}}} \\ {= {K_{O}{\overset{k}{\sum\limits_{- \infty}}e_{k}}}} \\ {= {K_{O}{\sum\limits_{- \infty}^{k}\left( {{x_{k}(b)} - {z_{k}(b)}} \right)}}} \\ {= {K_{O}\left\lbrack {{\sum\limits_{- \infty}^{k}{x_{k}(b)}} - {\sum\limits_{- \infty}^{k}{z_{k}(b)}}} \right\rbrack}} \end{matrix} & (12) \end{matrix}$

Similar to above, the second term in Equation 12 averages to zero so substituting in the offset compensation gradient from Equation 8 and replacing the second term in Equation 12 with 0 results in the offset gradient equation shown in Equation 2. Note that the offset gradient equation of Equation 2 does not depend upon the instantaneous value, nor does the equation depend upon a decision.

FIG. 4A is a flowchart illustrating an embodiment of a process for determining a gain gradient using the expected value of the square of an expected signal. In some embodiments, data independent error computation block 106 in FIG. 1 performs the example process of this figure. At 400, an expected value of a square of an expected signal is obtained (e.g., E[z_(k) ²(b)]). A signal is received at 402. For example, x_(k)(b) is received at data independent error computation block 106 in FIG. 1 from ADC 102. The received signal is squared at 404 (e.g., x_(k)(b)²) and the expected value of the square of the expected signal is subtracted from the square of the received signal to obtain a gain gradient at 406. That is: {tilde over (∇)}_(G) ^((k)) =x _(k)(b)² =E[z _(k) ²(b)]  (13)

Note that Equation 13 depends only upon a known property of the expected signal (in this particular embodiment, E[z_(k) ²(b)]) which is known or can be determined, even if the instantaneous value is not known. Equation 13 also does not depend upon decisions and therefore does not require the use of a detector or decoder. A description of how the gain gradient shown in Equation 13 is obtained is provided after the description of FIG. 4B.

FIG. 4B is a flowchart illustrating an embodiment of a process for determining a gain gradient using the expected value of the absolute value of an expected signal. In some embodiments, data independent error computation block 106 in FIG. 1 performs the example process shown in this figure. At 450, an expected value of an absolute value of an expected signal is obtained (e.g., E[|z_(k)(b)|]). A signal is received at 452 and the absolute value of the received signal is taken at 454 (e.g., |x_(k)(b)|). At 456, the expected value of the absolute value of the expected signal is subtracted from the absolute value of the received signal to obtain a gain gradient. That is: {tilde over (∇)}_(G) ^((k)) =|x _(k)(b)|−E[|z _(k)(b)|]  (14)

As with Equation 13, Equation 14 does not depend upon the instantaneous value of the expected signal, nor does it depend upon a decision output by a detector. In some embodiments, the squaring operation performed in Equation 13 is difficult and/or expensive to perform in hardware (e.g., when implemented as an ASIC or FPGA) and Equation 14 is preferred over Equation 13 because of the costs associated with squaring (or multiplying in general).

Next, it is shown how the gain gradients of Equations 13 and 14 are obtained. As above, equations that depend upon decisions or instantaneous values of the expected signal are first derived and then equations which only depend upon known properties of the expected signal are obtained. First, Equation 10 is rewritten as:

$\begin{matrix} \begin{matrix} {G^{({k + 1})} = {K_{G}{\sum\limits_{- \infty}^{k}\nabla_{G}^{(k)}}}} \\ {= {K_{G}{\sum\limits_{- \infty}^{k}{e_{k} \cdot {x_{k}(b)}}}}} \\ {= {K_{G}{\sum\limits_{- \infty}^{k}{\left( {{x_{k}(b)} - {z_{k}(b)}} \right) \cdot {x_{k}(b)}}}}} \\ {= {K_{G}\left\lbrack {{\sum\limits_{- \infty}^{k}{x_{k}^{2}(b)}} - {\sum\limits_{- \infty}^{k}{{x_{k}(b)} \cdot {z_{k}(b)}}}} \right\rbrack}} \\ {= {K_{G}\left\lbrack {{\sum\limits_{- \infty}^{k}{x_{k}^{2}(b)}} - {\sum\limits_{- \infty}^{k}{\left( {{e_{k}(b)} + {z_{k}(b)}} \right) \cdot {z_{k}(b)}}}} \right\rbrack}} \\ {= {K_{G}\left\lbrack {{\sum\limits_{- \infty}^{k}{x_{k}^{2}(b)}} - {\sum\limits_{- \infty}^{k}{z_{k}^{2}(b)}} - {\sum\limits_{- \infty}^{k}{{e_{k}(b)} \cdot {z_{k}(b)}}}} \right\rbrack}} \end{matrix} & (15) \end{matrix}$

The last term averages to zero since e_(k)(b) and z_(k)(b) are uncorrelated and zero mean which produces:

$\begin{matrix} \begin{matrix} {G^{({k + 1})} \approx {K_{G}\left\lbrack {{\sum\limits_{- \infty}^{k}{x_{k}^{2}(b)}} - {\sum\limits_{- \infty}^{k}{z_{k}^{2}(b)}}} \right\rbrack}} \\ {= {K_{G}{\sum\limits_{- \infty}^{k}\left( {{x_{k}^{2}(b)} - {z_{k}^{2}(b)}} \right)}}} \end{matrix} & (16) \end{matrix}$

The second term in Equation 16 is not known (since the instantaneous value of z_(k)(b) is not known) and so it is replaced in Equation 16 by the expected value of the square (i.e., E[z_(k) ²(b)]) to obtain:

$\begin{matrix} {G^{({k + 1})} \approx {K_{G}{\sum\limits_{- \infty}^{k}\left( {{x_{k}^{2}(b)} - {E\left\lbrack {z_{k}^{2}(b)} \right\rbrack}} \right)}}} & (17) \end{matrix}$

Then, using the gain gradient equation from Equation 9, Equation 13 associated with FIG. 4A is obtained. To obtain Equation 14 associated with FIG. 4B, Equation 13 is simplified into the form shown in Equation 14.

In some embodiments, the error signals described in FIGS. 3-4B have a variance that is significantly larger than that of their data dependent counterparts. Similarly, when the signal quality is good (i.e., which means few errors happen and the decision directed technique performs close to the data aided technique), the variance of the data independent technique described herein is also larger than that of the decision directed technique. For example, the variance of the offset gradient {tilde over (∇)}_(O) is:

$\begin{matrix} \begin{matrix} {{E\left\lbrack {\overset{\sim}{\nabla}}_{o}^{2} \right\rbrack} = {E\left\lbrack {x_{k}^{2}(b)} \right\rbrack}} \\ {= {E\left\lbrack \left( {e_{k} + {z_{k}(b)}} \right)^{2} \right\rbrack}} \\ {= {{E\left\lbrack e_{k}^{2} \right\rbrack} + {E\left\lbrack {z_{k}^{2}(b)} \right\rbrack}}} \end{matrix} & (18) \end{matrix}$ which is larger than the variance of {tilde over (∇)}_(O): E[{tilde over (∇)} _(O) ² ]=E[e _(k) ²]  (19)

As a result, in some embodiments the bandwidth of a low pass filter when a data independent technique is used is relatively low (e.g., lower than when decision directed techniques are used).

In some embodiments, a data independent error correction technique is used in combination with one or more other error correction techniques. The following figures show some embodiments in which signal quality is used to select between data independent and decision directed error correction. In some other embodiments, other error correction techniques are used in addition to or as an alternative to the examples shown herein. For example, in some embodiments, a 3:1 multiplexer is used that selects between decision directed, data independent and data aided error correction. In some other embodiments, a 2:1 multiplexer is used that selects between data independent and data aided error correction.

FIG. 5 is a block diagram showing an embodiment of a system which uses signal quality to select between data independent error correction and decision directed error correction. In the example shown, digital samples are output from ADC 500 and are passed to signal quality estimator 502, data independent error computation block 504 and decision directed error computation block 506. As described above, decision directed error computation block 506 calculates an error signal based on a decision (generated by an LDPC decoder, Viterbi decoder or other decoder) about what the received data is. Signal quality estimator 502 generates a control signal which controls multiplexer 508. In this example, the control signal generated by the signal quality estimator depends upon the signal quality of x_(k) (e.g., over a window of time) input to estimator 502.

Error computation blocks 504 and 506 output respective gain gradients and offset gradients and the gradient pair selected (using signal quality estimator 502 and multiplexer 508) are passed to low pass filters 510 a and 510 b, which output, respectively, a gain compensation value and an offset compensation value.

In various embodiments, a signal quality estimator determines a variety of signal quality parameters based on the samples passed to it (x_(k) in this figure). These signal quality parameters are used to make a decision about which error correction technique to use. Some example signal quality parameters include gain, offset, or signal to noise ratio. In various embodiments, various portions of the signal are used to determine these signal quality parameters. The following figures show various embodiments used by signal quality estimator 502 in selecting an error correction technique.

FIG. 6 is a diagram showing an embodiment of a data structure. In the example shown, diagram 600 shows an exemplary waveform of a data structure used to store or transmit data. The exemplary data structure has three portions or sections: preamble 602, synchronization mark 604 and payload data portion 606 (which contains variable content). In some applications, a preamble is used to acquire timing (e.g., adjust a sampling clock) and make other adjustments and/or a synchronization mark is used to indicate the end of the preamble and the start of a payload data portion.

In the example shown, preamble 602 and synchronization mark 604 are fixed or (more generally) predefined patterns. As such, the instantaneous value for those portions is known ahead of time (e.g., by a receiver in a communications system or by a read processor in a storage system). In contrast, the contents of payload data 606 vary (e.g., from sector to sector or from packet to packet) and the instantaneous value of that portion is typically not known.

In some embodiments, a signal quality estimator (e.g., 502 in FIG. 5) uses preamble 602 and/or synchronization mark 604 to determine signal quality parameters (e.g., related to gain, offset, SNR, etc.) which are in turn used to select an error correction technique. The following figures show some embodiments of processes that use one or both of these portions of a data structure.

The format shown in diagram 600 is exemplary and in other embodiments may include other portions in addition to or as an alternative to those shown herein. For example in a communications application, data may be transmitted in the form of a packet and in storage applications data may be stored in the form of a sector; the particular format of the packet or sector may vary depending upon the particular application or standard used.

FIG. 7 is a flowchart illustrating an embodiment of a technique to determine an average amplitude and average offset in order to select an error correction technique. In the example shown, the process uses the preamble portion of a received signal (e.g., preamble 602 in FIG. 6) to determine signal quality. Other portions of the received signal (at least in this example) are not necessarily used. In this embodiment and other embodiments (e.g., described below), the process may be repeated at the beginning of each packet or sector and once an error correction technique is selected it is used for the entire sector or packet. For example, one sector may have a good signal quality and it is okay to use decision directed error correction, whereas another sector may have a poor signal quality and it would not be desirable to use decision directed error correction.

At 700, a preamble of a received signal is sampled four times. In some applications, a preamble has repeated pattern of 1100 and its waveform resembles a sine wave. An amplitude (A_(i)) and an offset (O_(i)) are determined for those samples at 702. For example, the four samples obtained at 700 are x₁, x₂, x₃ and x₄ and the amplitude is determined using the equation A_(i)=0.5√{square root over ((x₁−x₃)²+(x₂−x₄)²)}{square root over ((x₁−x₃)²+(x₂−x₄)²)} and the offset is determined using the equation O_(i)=(x₁+x₂+x₃+x₄)/4.

At 704 it is determined whether to obtain more samples. The received signal may be noisy and more samples are obtained in order to obtain an average which reduces or eliminates noise. In some embodiments, all available samples in a preamble are used and the decision at 704 is based on whether the end of the preamble has been reached. If it is determined to obtain more samples, the preamble is sampled again at 700. Otherwise, the amplitudes (A_(i)) and offsets (O_(i)) are averaged to obtain an average amplitude (Ā) and an average offset (Ō) at 706.

At 708 it is determined whether the average amplitude (Ā) is between the range thresh_(Ā,low) and thresh_(Ā,high). If the amplitude is too large, the signal quality may be low because (for example) the received signal has a large interfering signal included in it. Or, when the amplitude is too large, the after ADC signal will get saturated and waveform will be distorted. Similarly, if the amplitude is too low, the signal quality may be poor because (for example) the read head was not properly positioned over the track or the transmission channel significantly attenuated the received signal.

If it is determined at 708 that the average amplitude is not within the range of thresh_(Ā,low) and thresh_(Ā,high) then a data independent error computation technique is selected at 712. For example, in FIG. 5, signal quality estimator 502 would output a control signal to multiplexer 508 which would select data independent error computation block 504. Otherwise, it is determined at 710 whether the average offset Ō is greater than a threshold thresh_(Ō). A large offset tends to correspond to a poor signal quality and so if the average offset Ō is greater than thresh_(Ō) then data independent error computation is selected at 712. Otherwise, decision directed error computation is selected at 714.

FIG. 8A is a flowchart illustrating an embodiment of a technique to determine an amplitude difference metric and offset difference metric in order to select an error correction technique. In the example shown, the process uses the synchronization mark portion of a received signal (e.g., synchronization mark 604 in FIG. 6) to determine signal quality.

At 800, an amplitude difference metric (e_(A)) is determined using a synchronization mark of a received signal. The data pattern is predefined (i.e., the instantaneous value of the synchronization mark portion is known) and in this example an amplitude difference metric is obtained using the equation

$e_{A} = {\sum\limits_{i = 0}^{L - 1}{{{sign}\left( {\hat{x}}_{i} \right)}\left( {x_{i} - {\hat{x}}_{i}} \right)}}$ where x_(i) is a sample during the synchronization mark portion of a received signal and L is the sync-mark length. In some embodiments, {circumflex over (x)}_(i) is the instantaneous value of the synchronization mark. In some embodiments, {circumflex over (x)}_(i) is the instantaneous value of the synchronization mark after passing through a channel model (e.g., the instantaneous value with an impulse response applied). The function sign (·) produces a 1 when the input is positive, a −1 when the input is negative and a 0 when the input is zero. As a result, when the incoming signal is too large, e_(A) will be positive and when the incoming signal is too small, e_(A) will be negative.

At 802, an offset difference metric (e_(O)) is determined using a synchronization mark of a received signal. In some embodiments,

$e_{o} = {- {\sum\limits_{i = 0}^{L - 1}{\left( {x_{i} - {\hat{x}}_{i}} \right).}}}$

Turning briefly to the next figure, FIG. 8B is a diagram showing exemplary plots of an amplitude difference metric and an offset difference metric. In the example shown, the top graph (850) shows amplitude difference metric (e_(A)) as a function of a voltage gain amplifier (VGA) gain control value difference, obtained from simulation. As can be seen, when the difference to the correct gain value is zero, the amplitude difference metric (e_(A)) is close to zero.

Similarly, the bottom graph (852) shows the offset difference metric (e_(O)) as a function of a control signal or adjustment amount to a correct offset, also obtained from simulation. Similarly, when there is no offset (i.e., the x-axis is zero), the metric e_(O) is close to zero.

Returning back to FIG. 8A, it is determined at 804 whether the amplitude difference metric (e_(A)) is between the range of thresh_(A,low) and thresh_(A,high). If it is not, data independent error computation is selected at 808. If it is determined to be between the range of thresholds at 804 then it is determined at 806 whether the offset difference metric (e_(O)) is between the range of thresh_(O,low) and thresh_(O,high). If it is, then decision directed error computation is selected at 810. If not, data independent error computation is selected at 808.

FIG. 9A is a flowchart illustrating an embodiment of a technique to determine a synchronization mark distance in order to select an error correction technique. In the example shown, the process uses the synchronization mark portion of a received signal (e.g., synchronization mark 604 in FIG. 6) to determine signal quality.

At 900, a synchronization mark distance (d) is determined using a synchronization mark of a received signal. For example, the equation

$d = {\sum\limits_{i = 0}^{L - 1}{{x_{i} - {\hat{x}}_{i}}}}$ is used. As described above, the instantaneous value of the synchronization mark is known (and therefore the second term in the equation is known) and x_(i) are samples from the received signal. The value of d measures the distance between the received signal and an ideal or expected signal during the synchronization mark. When gain and offset are in their appropriate range, if signal SNR is bad, this distance will be larger than that for a better or more typical SNR condition.

Turning temporarily to FIG. 9B, FIG. 9B is a diagram showing an embodiment of synchronization mark distance plotted as a function of a noise factor. In the example shown, the noise factor is related to or otherwise proportional to SNR. A larger distance is therefore indicative of a larger noise factor since the distance increases with noise factor.

Returning back to FIG. 9A, it is determined at 902 if the synchronization mark distance (d) is greater than a threshold thresh_(d). If so, data independent error computation is selected at 904. If it is not, decision directed error computation is selected at 906.

As shown above, there are a variety of techniques for calculating various signal quality parameters to be used in selecting an error correction technique. In some cases, two or more signal quality parameters yield roughly the same results and therefore other factors (e.g., computational complexity or other hardware limitations) may be used to select one selection technique over another.

Although the foregoing embodiments have been described in some detail for purposes of clarity of understanding, the invention is not limited to the details provided. There are many alternative ways of implementing the invention. The disclosed embodiments are illustrative and not restrictive. 

The invention claimed is:
 1. A system for adjusting an analog front end, comprising: a signal equality estimator configured to: input one or more digital samples; determine a signal quality based at least in part on the digital samples; and determine if the signal quality satisfies one or more criteria; a data independent error computation block configured to generate a data independent gain gradient and a data independent offset gradient without taking into consideration an instantaneous value of an expected signal; a decision directed error computation block configured to generate a decision directed gain gradient and a decision directed offset gradient based at least in part on one or more decisions; and a multiplexer configured to: in the event it is determined that the signal quality satisfies the criteria, select the data independent gain gradient and the data independent offset gradient to adjust the analog front end; and in the event it is determined that the signal quality does not satisfy the criteria, select the decision directed gain gradient and the decision directed offset gradient to adjust the analog front end.
 2. The system of claim 1, wherein the system includes one or more of the following: an application-specific integrated circuit (ASIC) or a field-programmable gate array (FPGA).
 3. The system of claim 1, wherein: the digital samples input by the signal equality estimator include one or more preamble samples; and the signal equality estimator is further configured to generate an average amplitude and an average offset based at least in part on the preamble samples, wherein the average amplitude and the average offset are used to determine if the signal quality satisfies the criteria.
 4. The system of claim 3, wherein in the event the average amplitude is less than a low amplitude threshold or the average amplitude is greater than a high amplitude threshold, the criteria is not satisfied and the multiplexer selects the data independent gain gradient and the data independent offset gradient.
 5. The system of claim 4, wherein in the event the average amplitude is between the low amplitude threshold and the high amplitude threshold: in the event the average offset is greater than an offset threshold, the criteria is not satisfied and the multiplexer selects the data independent gain gradient and the data independent offset gradient; and in the event the average offset is less than the offset threshold, the criteria is satisfied and the multiplexer selects the decision directed gain gradient and the decision directed offset gradient.
 6. The system of claim 1, wherein: the digital samples input by the signal equality estimator include one or more synchronization marks; and the signal equality estimator is further configured to generate an amplitude difference metric and an offset difference metric based at least in part on the synchronization marks, wherein the amplitude difference metric and the offset difference metric are used to determine if the signal quality satisfies the criteria.
 7. The system of claim 6, wherein in the event the amplitude difference metric is less than a low amplitude threshold or the amplitude difference metric is greater than a high amplitude threshold, the criteria is not satisfied and the multiplexer selects the data independent gain gradient and the data independent offset gradient.
 8. The system of claim 7, wherein in the event the amplitude difference metric is between the low amplitude threshold and the high amplitude threshold: in the event the offset difference metric is less than an low offset threshold or the offset difference metric is greater than a high offset threshold, the criteria is not satisfied and the multiplexer selects the data independent gain gradient and the data independent offset gradient; and in the event the offset difference metric is between the low offset threshold and the high offset threshold, the criteria is satisfied and the multiplexer selects the decision directed gain gradient and the decision directed offset gradient.
 9. The system of claim 1, wherein: the digital samples input by the signal equality estimator include one or more synchronization marks; and the signal equality estimator is further configured to generate a synchronization mark distance based at least in part on the synchronization marks, wherein the synchronization mark distance is used to determine if the signal quality satisfies the criteria.
 10. The system of claim 9, wherein: in the event the synchronization mark distance is greater than a distance threshold, the criteria is not satisfied and the multiplexer selects the data independent gain gradient and the data independent offset gradient; and in the event the synchronization mark distance is less than the distance threshold, the criteria is satisfied and the multiplexer selects the decision directed gain gradient and the decision directed offset gradient.
 11. A method for adjusting an analog front end, comprising: receiving one or more digital samples; using a signal processor to determine a signal quality based at least in part on the digital samples; determining if the signal quality satisfies one or more criteria; in the event it is determined that the signal quality satisfies the criteria, selecting a data independent gain gradient and a data independent offset gradient to adjust the analog front end, wherein the data independent gain gradient and the data independent offset gradient are generated without taking into consideration an instantaneous value of an expected signal; and in the event it is determined that the signal quality does not satisfy the criteria, selecting a decision directed gain gradient and a decision directed offset gradient to adjust the analog front end, wherein the decision directed gain gradient and the decision directed offset gradient are generated based at least in part on one or more decisions.
 12. The method of claim 11, wherein the method is performed by one or more of the following: an application-specific integrated circuit (ASIC) or a field-programmable gate array (FPGA).
 13. The method of claim 11, wherein: the digital samples received include one or more preamble samples; and the method further includes generating an average amplitude and an average offset based at least in part on the preamble samples, wherein the average amplitude and the average offset are used to determine if the signal quality satisfies the criteria.
 14. The method of claim 13, wherein in the event the average amplitude is less than a low amplitude threshold or the average amplitude is greater than a high amplitude threshold, the criteria is not satisfied and the data independent gain gradient and the data independent offset gradient are selected.
 15. The method of claim 14, wherein in the event the average amplitude is between the low amplitude threshold and the high amplitude threshold: in the event the average offset is greater than an offset threshold, the criteria is not satisfied and the data independent gain gradient and the data independent offset gradient are selected; and in the event the average offset is less than the offset threshold, the criteria is satisfied and the decision directed gain gradient and the decision directed offset gradient are selected.
 16. The method of claim 11, wherein: the digital samples received include one or more synchronization marks; and the method further includes generating an amplitude difference metric and an offset difference metric based at least in part on the synchronization marks, wherein the amplitude difference metric and the offset difference metric are used to determine if the signal quality satisfies the criteria.
 17. The method of claim 16, wherein in the event the amplitude difference metric is less than a low amplitude threshold or the amplitude difference metric is greater than a high amplitude threshold, the criteria is not satisfied and the data independent gain gradient and the data independent offset gradient are selected.
 18. The method of claim 17, wherein in the event the amplitude difference metric is between the low amplitude threshold and the high amplitude threshold: in the event the offset difference metric is less than an low offset threshold or the offset difference metric is greater than a high offset threshold, the criteria is not satisfied and the data independent gain gradient and the data independent offset gradient are selected; and in the event the offset difference metric is between the low offset threshold and the high offset threshold, the criteria is satisfied and the decision directed gain gradient and the decision directed offset gradient are selected.
 19. The method of claim 11, wherein: the digital samples received include one or more synchronization marks; and the method further includes generating a synchronization mark distance based at least in part on the synchronization marks, wherein the synchronization mark distance is used to determine if the signal quality satisfies the criteria.
 20. The method of claim 19, wherein: in the event the synchronization mark distance is greater than a distance threshold, the criteria is not satisfied and the data independent gain gradient and the data independent offset gradient are selected; and in the event the synchronization mark distance is less than the distance threshold, the criteria is satisfied and the decision directed gain gradient and the decision directed offset gradient are selected. 